import request from "@/utils/request";

// 登录
export function login(data) {
  return request({
    url: "/login?terminal_type=PC",
    method: "post",
    data,
  });
}

// 用户注册
export function register(data) {
  return request({
    url: "/system/user/register",
    method: "post",
    data,
  });
}

// 查询当前用户信息
export function getInfo(params) {
  return request({
    url: "/getInfo",
    method: "get",
    params,
  });
}

// 获取验证码
export function getVerificationCode(params) {
  return request({
    url: "/getVerificationCode",
    method: "get",
    params,
  });
}

// 手机验证码登录
export function phoneLogin(data) {
  return request({
    url: "/phoneLogin?terminal_type=PC",
    method: "post",
    data,
  });
}